<script>
import { loginPage } from "@/permission";
import { getToken } from "@/utils/storage";

export default {
  onLaunch: function () {
    this.initApp();
  },
  onShow: function () {
    console.log("App Show");
  },
  onHide: function () {
    console.log("App Hide");
  },
  methods: {
    initApp() {
      // this.checkLogin();
    },
    checkLogin() {
      if (!getToken()) {
        this._jump(loginPage, {});
      }
    },
  },
};
</script>

<style lang="scss">
@use "@/assets/scss/index.scss" as *;
@use "@/uni_modules/cool-unix/index.scss" as *;
</style>
